remove costly availability check that is never used
authorMatthieu Gallien <matthieu.gallien@nextcloud.com>
Fri, 4 Apr 2025 14:00:23 +0000 (16:00 +0200)
committerMatthieu Gallien <matthieu.gallien@nextcloud.com>
Mon, 7 Apr 2025 11:53:29 +0000 (13:53 +0200)
we never read the value computed

computing it means a recursive visit of the whole folder hierarchy which
could be taking a long time

Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
src/libsync/propagatorjobs.cpp

index 86086c3357e14e823f863e1767179a6a0312c347..002480c82705d1f124a55ea9e9d7656d78c75280 100644 (file)
@@ -107,7 +107,6 @@ void PropagateLocalRemove::start()
     }
 
     QString removeError;
-    const auto availability = propagator()->syncOptions()._vfs->availability(_item->_file, Vfs::AvailabilityRecursivity::RecursiveAvailability);
     if (_moveToTrash && propagator()->syncOptions()._vfs->mode() != OCC::Vfs::WindowsCfApi) {
         if ((QDir(filename).exists() || FileSystem::fileExists(filename))
             && !FileSystem::moveToTrash(filename, &removeError)) {